package com.parktech.sun.domain.model.downloadcenter;

import com.parktech.sun.domain.model.BaseEntity;

import javax.persistence.*;

/**
 * User: Think
 * Date: 2010-12-20
 * Time: 1:49:55
 */
@Entity
public class ResourceFile extends BaseEntity {

    private String fileName;

    private String fileSize;

    private String fileType;

    private Integer orderCode;

    private Integer publishStatus;

    private Integer accessPermission = 0;

    private int downloadCount;

    private String publishDate;

    private ResourceType category;

    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    public Long getId() {
        return id;
    }

    public String getFileName() {
        return fileName;
    }

    public void setFileName(String fileName) {
        this.fileName = fileName;
    }

    public String getFileSize() {
        return fileSize;
    }

    public void setFileSize(String fileSize) {
        this.fileSize = fileSize;
    }

    public String getFileType() {
        return fileType;
    }

    public void setFileType(String fileType) {
        this.fileType = fileType;
    }

    public int getDownloadCount() {
        return downloadCount;
    }

    public Integer getOrderCode() {
        return orderCode;
    }

    public void setOrderCode(Integer orderCode) {
        this.orderCode = orderCode;
    }

    public void setDownloadCount(int downloadCount) {
        this.downloadCount = downloadCount;
    }

    public String getPublishDate() {
        return publishDate;
    }

    public void setPublishDate(String publishDate) {
        this.publishDate = publishDate;
    }

    public Integer getPublishStatus() {
        return publishStatus;
    }

    public void setPublishStatus(Integer publishStatus) {
        this.publishStatus = publishStatus;
    }

    @ManyToOne
    public ResourceType getCategory() {
        return category;
    }

    public void setCategory(ResourceType category) {
        this.category = category;
    }

    public Integer getAccessPermission() {
        return accessPermission;
    }

    public void setAccessPermission(Integer accessPermission) {
        this.accessPermission = accessPermission;
    }
}
